Ext.ns('tj');

tj.SearchResultsPanel = Ext.extend(Ext.Panel, {

    initComponent: function () {
	this.flex = 1;
	this.height = 1000;

	this.items = [{
	    xtype: 'spacer',
	    height: 10
	},{
	    xtype: 'container',
	    layout: 'hbox',
	    height: '40',
	    items: [{
		xtype: 'spacer',
		width: 10
	    },{
		xtype: 'label',
		html: '<b>Search Results:</b>',
		width: 200
	    },{
		xtype: 'spacer',
		flex: 1
	    },{
		xtype: 'label',
		text: '<Prev 1 2 3 Next>',
		width: 150
	    },{
		xtype: 'spacer',
		wdith: 5
	    }]
	},{
	    xtype: 'spacer',
	    height: 10
	},{
	    xtype: 'grid',
	    height: 950,
	    columns: [
		{ header: 'Job Title', dataIndex: 'jobTitle',
		  renderer: function(value, metadata) {
		      return  '<a href="jobreview.html">' + value + '</a>';
		  },
		  css: 'font-size:14;'
		},
		{ header: 'Employer', dataIndex: 'employer', css: 'font-size:14;' },
		{ header: 'Location', dataIndex: 'location', css: 'font-size:14;' },
		{ header: 'Division', dataIndex: 'division', css: 'font-size:14;' }
	    ],
	    store: new Ext.data.ArrayStore({
		fields: ['employer', 'jobTitle', 'location', 'division'],
		data: [
		    ['Reseach In Motion (Rim)', 'Software Developer', 'Waterloo', 'Audio'],
		    ['General Motors (GM)', 'Line Engineer', 'Toronto', 'Production'],
		    ['BlueCoat', 'Software Developer', 'Waterloo', 'Security'],
		    ['Crap Job Inc. #1', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #2', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #3', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #4', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #5', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #6', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #7', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #8', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #9', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #10', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #11', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #12', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #13', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #14', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #15', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #16', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #17', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #18', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #19', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support'],
		    ['Crap Job Inc. #20', 'Caffinated Beverage Retrieval Specialist', 'CrapsVille', 'Tech Support']
		]
	    }),
	    viewConfig: {
		forceFit: true
	    }
	}];

	tj.SearchResultsPanel.superclass.initComponent.apply(this, arguments);
    }

});

Ext.reg('tj.searchresultspanel', tj.SearchResultsPanel);